package cn.xiongxf.web.controller;

import cn.xiongxf.domain.Blacklist;
import cn.xiongxf.query.BlacklistQuery;
import cn.xiongxf.result.JsonResult;
import cn.xiongxf.result.PageList;
import cn.xiongxf.service.IBlacklistService;
import cn.xiongxf.service.ITokenService;
import com.baomidou.mybatisplus.plugins.Page;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/common")
public class TokenController {


    @Autowired
    public ITokenService tokenService;

    /**
     * 创建订单的令牌
     */
    @RequestMapping(value = "/createToken/{courseId}",method = RequestMethod.GET)
    public JsonResult creatToken(@PathVariable("courseId")String courseIds){
        String token = tokenService.creatToken(courseIds);
        return JsonResult.success(token);
    }

}
